package com.movitech.mobile.cz.base.supplier.service.impl;

import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.movitech.mobile.cz.base.supplier.entity.SSuppliersMbsContacts;
import com.movitech.mobile.cz.base.supplier.entity.ext.ExtSSuppliersMbsContacts;
import com.movitech.mobile.cz.base.supplier.mapper.SSuppliersMbsContactsMapper;
import com.movitech.mobile.cz.base.supplier.mapper.ext.ExtSSuppliersMbsContactsMapper;
import com.movitech.mobile.cz.base.supplier.service.SSuppliersMbsContactsService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * mbs合同数据 服务实现类
 * </p>
 *
 * @author Movitech Mobile
 * @since 2018-07-23
 */
@Service
public class SSuppliersMbsContactsServiceImpl extends ServiceImpl<SSuppliersMbsContactsMapper, SSuppliersMbsContacts> implements SSuppliersMbsContactsService {
    @Autowired
    private ExtSSuppliersMbsContactsMapper extSSuppliersMbsContactsMapper;
    @Override
    public List<SSuppliersMbsContacts> findSimListByName(String name) {
        EntityWrapper entityWrapper = new EntityWrapper();
        entityWrapper.like("contact_name",name).eq("del_flag",0);
        return selectList(entityWrapper);
    }

    @Override
    public ExtSSuppliersMbsContacts findExtById(String id) {
        return extSSuppliersMbsContactsMapper.findExtById(id);
    }
}
